#!/usr/bin/env python
import os
from shutil import copyfile

# When you "Build and Download" from Crowdin, you endup with a qgroundcontro.zip file.
# It is assumed this zip file has been extracted into ./mysoft

for lang in os.listdir("./mysoft"):
    srcFile = os.path.join("./mysoft", lang, "my.ts")
    if(os.path.exists(srcFile)):
        lang = lang.replace("-","_")
        dstFile = "./my" + "_" + lang + ".ts"
        print("my" + "_" + lang + ".ts")
        copyfile(srcFile, dstFile)

